package com.framework.spring.domain;

import com.framework.spring.annotations.Autowired;
import com.framework.spring.annotations.Component;
import com.framework.spring.annotations.PostConstruct;

/**
 * @author duanzhizhou
 * @date 2025/4/8
 */
@Component
public class Cat {
    
    @Autowired
    private Dog dog;
    
    public Dog getDog() {
        return dog;
    }
    
    public void setDog(Dog dog) {
        this.dog = dog;
    }
    
    @PostConstruct
    public void init() {
        System.out.println("Cat 创建了，里面有一个" + dog);
    }
}
